package cn.edu.scau.cmi.yangjiamin.client;


import cn.edu.scau.cmi.yangjiamin.interProgramming.Experiment1;
import javafx.application.Application;
import javafx.geometry.Insets;
import javafx.scene.Scene;
import javafx.scene.control.Button;
import javafx.scene.layout.BorderPane;
import javafx.scene.layout.HBox;
import javafx.scene.text.Text;
import javafx.stage.Stage;

public class InterProgrammingClient extends Application{
	@Override
	public void start(Stage primaryStage) {
		BorderPane pane = new BorderPane();
		HBox hbox = new HBox();
		hbox.setPadding(new Insets(10, 10, 10, 10));
		Button show = new Button("显示");
		
		hbox.getChildren().addAll(show);
		Text text =  new Text(100, 100, "显示结果");
		show.setOnAction(e->{
			Experiment1 ex1 = new Experiment1("experiment1 finish!");
			text.setText(ex1.getS());
		});
		
		pane.setTop(hbox);
		pane.setCenter(text);
		Scene scene = new Scene(pane, 600, 500);
		primaryStage.setTitle("InterProgrammingClient");
		primaryStage.setScene(scene);
		primaryStage.show();
	}
	
	

}
